﻿/*
 * Created by SharpDevelop.
 * User: DELL
 * Date: 7/28/2012
 * Time: 3:29 PM
 * 
 * To change this template use Tools | Options | Coding | Edit Standard Headers.
 */

using System;

namespace IntoNails.Models
{
	/// <summary>
	/// Description of Authority.
	/// </summary>
	public class Authority
	{
		public Guid AuthorityCode { get; set; }
		public string AuthorityName { get; set; }
		public string Description { get; set; }
		public DateTime CreatedDate { get; set; }
		public DateTime UpdatedDate { get; set; }
		public bool IsValid { get; set; }
		
		public static Authority CreateNewAuthority()
		{
			return new Authority();
		}
		
		public static Authority CreateAuthority(string name, string description)
		{
			return new Authority {
				AuthorityCode = Guid.NewGuid(),
				AuthorityName = name,
				Description = description,
				CreatedDate = DateTime.UtcNow,
				UpdatedDate = DateTime.UtcNow,
				IsValid = true
			};
		}
	}
}
